const express = require('express')

const router = express.Router()

const {
    getall,
    search,
    catDish,
    getOne
} = require('../../../controller/dish')

//商品相关请求
//获取所有商品
router.get('/getall', getall)

//根据关键字获取对应商品
router.get('/search/:keywords', search)

//获取某个分类下的所有商品
router.get('/catDish/:catname', catDish)

//根据商品id获取商品信息
router.get('/getOne/:dishId', getOne)

module.exports = router